package com.ruoyi.parttime.chat.domain;

import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 客服聊天对象 chat_service
 *
 * @author ruoyi
 * @date 2024-06-01
 */
@Data
public class ChatService extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    private Long id;

    /**
     * 消息发送者id
     */
    @Excel(name = "消息发送者id")
    private Long sendUserId;

    /**
     * 聊天内容文件地址
     */
    @Excel(name = "聊天内容文件地址")
    private String messageFile;

    /**
     * 消息读的状态 0：未读 1：已读
     */
    @Excel(name = "消息读的状态 0：未读 1：已读")
    private Integer readStatus;

    /**
     * 消息发送者头像地址
     */
    @Excel(name = "消息发送者头像地址")
    private String sendUserAvatar;

    /**
     * 消息接收者头像地址
     */
    @Excel(name = "消息接收者头像地址")
    private String serviceAvatar;

    /**
     * 消息接收者id
     */
    @Excel(name = "消息接收者id")
    private Long receiveUserId;

    /**
     * 消息发送者的nickName
     */
    private String nickName;

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("sendUserId", getSendUserId())
                .append("messageFile", getMessageFile())
                .append("readStatus", getReadStatus())
                .append("sendUserAvatar", getSendUserAvatar())
                .append("serviceAvatar", getServiceAvatar())
                .append("receiveUserId", getReceiveUserId())
                .toString();
    }
}
